package com.freight.user.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.freight.user.dto.DriverDto;
import com.freight.user.entity.DriverUser;
import com.freight.user.vo.*;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 司机详情信息数据处理层
 *
 * @author huyingtai
 */
public interface DriverVoMapper extends BaseMapper<UserVo> {

    /**
     * 通过车辆id获取订单id
     *
     * @param vehicleId
     */
    List<Long> getVehicleOrder(@Param("vehicleId") Long vehicleId);

    Integer getOederdriverUser(@Param(value = "userId")  Long userId);

    Integer getOederActualCarrierUser(@Param(value = "userId")  Long userId);

    Page<MsgConsultingListVo> complaintList(Page<MsgConsultingListVo> page,@Param(value = "userId")  Long userId);

    /**
     * 获取司机个人证件信息
     * @param userId
     */
    DriverInformationVo getDriverInformation(@Param(value = "userId") Long userId);

    List<ManageUserVo> getManageUserIdUser(@Param("mobile")  String mobile);


    /**
     * 根据驾驶证号获取信息
     * @param num
     * @return
     */
    List<DriverLicenseVo> getDriverLicense(@Param("num") String num);


    /**
     * 通过用户id获取
     *
     * @param userId
     */
    AppointDriverInfoVo getAppointDriverInfoByUserId(@Param("userId") Long userId);



    /**
     * 通过用户id获取
     *
     * @param userIds
     * @return AppointDriverInfoVo 信息
     */
    List<AppointDriverInfoVo> getAppointDriverInfoByUserIds(@Param("userIds") Long[] userIds);

    /**
     * 通过用户id获取
     *
     * @param userId
     */
    DriverInfoVo getDriverInfoByUserId(@Param("userId") Long userId);

    /**
     * 通过用户id获取
     *
     * @param userIds
     */
    List<DriverInfoVo> getDriverInfoByUserIds(@Param("userIds") Long[] userIds);

    /**
     * 通过用户id获取
     *
     * @param userId
     */
    DriverVo getDriverVoByUserId(@Param("userId") Long userId);


    /**
     * 通过用户id获取
     *
     * @param userId
     */
    DriverUser  getDriverVoUserId(@Param("userId") Long userId);

    /**
     * 通过用户id获取
     *
     * @param vehicleId
     */
    DriverUser  getDriverVoVehicleId(@Param("vehicleId") Long vehicleId);

    /**
     * 通过用户id获取
     *
     * @param userIds
     */
    List<DriverVo> getDriverVoByUserIds(@Param("userIds") Long[] userIds);

    /**
     * 通过用户id获取
     *
     * @param driverDto
     */
    Page<DriverDetailInfoVo> getDriverInfo(Page<DriverDetailInfoVo> page, @Param("driverDto") DriverDto driverDto);

    Page<DriverDetailInfoVo> getCompanyDriverInfo(Page<DriverDetailInfoVo> page, @Param("driverDto") DriverDto driverDto, @Param("userId") Long userId);

    /**
     *
     * @param driverDto
     * @return
     */
    List<DriverDetailInfoVo> getDriverInfo(@Param("driverDto") DriverDto driverDto);


    /**
     *
     * @param driverDto
     * @return
     */
    List<DriverInfoVo> getDriverBaseInfo(@Param("driverDto") DriverDto driverDto);

}